package com.ruicar.afs.cloud.basic.outer.api.common.gateway;

import com.ruicar.afs.cloud.basic.outer.api.common.dto.BasicCancelInfoConditionDto;
import com.ruicar.afs.cloud.common.core.util.IResponse;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Map;

/**
 * @author: xudongdong
 * @date: 2020/5/11 19:39
 * @description:
 */
@FeignClient(url = "${com.greatwall.services.contract-gateway.url}", name = "contract-apply")
public interface ContractToApplyGateWay {

    @ApiOperation("合同信息")
    @PostMapping(value = "/getContractDetailInfo")
    public IResponse getContractDetailInfo(@RequestParam(value = "contractNo") String contractNo, @RequestHeader Map<String, String> headers);

    @ApiOperation("根据合同号码和角色类型查询客户信息")
    @PostMapping(value = "/getCustInfo")
    public IResponse getCustInfo(@RequestParam(value = "contractNo") String contractNo, @RequestHeader Map<String, String> headers);

    @ApiOperation("根绝合同号码查询还款计划表列表信息")
    @PostMapping(value = "/getRepaymentPlanInfoList")
    public IResponse getRepaymentPlanInfoList(@RequestParam(value = "contractNo") String contractNo, @RequestHeader Map<String, String> headers);

    @ApiOperation("查询车辆（资产）信息")
    @PostMapping(value = "/getCarDetailInfo")
    public IResponse getCarDetailInfo(@RequestParam(value = "contractNo") String contractNo, @RequestHeader Map<String, String> headers);

    @ApiOperation("根据合同号码查询客户信息列表")
    @PostMapping(value = "/getCustInfoList")
    public IResponse getCustInfoList(@RequestParam(value = "contractNo") String contractNo, @RequestHeader Map<String, String> headers);

    @ApiOperation("新增申请弹框页面统一数据查询接口")
    @PostMapping(value = "/getContractInfoList")
    public IResponse getContractInfoList(@RequestBody BasicCancelInfoConditionDto condition, @RequestHeader Map<String, String> headers);
}
